﻿@using Git.Framework.DataTypes;
@using Git.Framework.DataTypes.ExtensionMethods;

@{
    Layout = null;
    Git.Storage.Entity.Biz.PurchaseEntity Entity = ViewBag.Entity;
}

<div class="form-horizontal">
    <div class="row-fluid">
        <div class="span4">
            <div class="control-group" style="margin-bottom:auto; margin-left:10px;">
                <label class="control-label ordertitle" style="width:auto;">订单号</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.OrderNum</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">单据类型</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Html.Raw(Git.Framework.DataTypes.EnumHelper.GetEnumDesc<Git.Storage.Common.Enum.EOrderType>(Entity.OrderType))</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">制单日期</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.OrderTime.To("yyyy-MM-dd")</span>
                </div>
            </div>
        </div>
    </div>
    <div class="row-fluid">
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">关联单号</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.ContractOrder</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">制单人</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.CreateUserName</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">发货日期</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.RevDate.To("yyyy-MM-dd")</span>
                </div>
            </div>
        </div>
    </div>
    <div class="row-fluid">
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">供应商编号</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.SupNum</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">供应商名称</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.SupName</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">联系人</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.Contact</span>
                </div>
            </div>
        </div>
    </div>
    <div class="row-fluid">
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">电话</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.Phone</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">状态</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Html.Raw(Git.Framework.DataTypes.EnumHelper.GetEnumDesc<Git.Storage.Common.Enum.EOrderStatus>(Entity.AuditeStatus))</span>
                </div>
            </div>
        </div>
        <div class="span4">
            <div class="control-group" style="margin-bottom: auto; margin-left: 10px;">
                <label class="control-label ordertitle" style="width:auto;">备注</label>
                <div class="controls" style="margin-left:5px;">
                    <span class="text">@Entity.Remark</span>
                </div>
            </div>
        </div>
    </div>

    <div class="row-fluid">
        <div class="span12">
            <div class="widget-body" style="border-bottom:0px;">
                <table class="table table-striped table-bordered table-hover" id="tabDetail">
                    <thead>
                        <tr>
                            <th>选择</th>
                            <th>产品名称</th>
                            <th>产品编码</th>
                            <th>规格</th>
                            <th>单价</th>
                            <th>单位</th>
                            <th>数量</th>
                            <th>退货数</th>
                            <th>总价</th>
                        </tr>
                    </thead>
                </table>
            </div>
        </div>
    </div>
</div>